<body style="padding-top: 2%;background-color:#eeeeee" <? echo $item = !isset($_SESSION['type']) ? 'onload="show();start();"' : ""?> >
    <?
        if (!isset($color)) {
            $color = '#3276b1';
        }
        ?>
        <div class="navbar navbar-inverse navbar-fixed-top" style= "background-color:<? echo $color; ?>">
            <div class="navbar-header">
                <span class="navbar-brand"><? echo $title ?></span>
            </div>
            
        </div>
    <div class="container">
    
    <div class="jumbotron" style="text-align: center;">
            <div class="col-md-9 col-md-offset-1">
                <h1><? echo $story['title']; ?></h1>
                <p><? echo $story['content']; ?></p>
                <a onClick ="stop();" data-toggle="modal" href="<?php echo base_url("questions/display/"); ?>" data-target='#questions'  class="btn btn-primary btn-lg" >Take Exam</a>
            </div>
    </div>
            </div>
     <? if (!isset($_SESSION['type'])){?>
            <div class="pull-right"><input type="text" id="time" value="00:00:00" disabled/></div>
                <?}?>
    <div class="modal fade" id="questions" tabindex="-1" role="dialog" aria-hidden="true"></div>

    <div class="modal fade" id="error" tabindex="-1" role="dialog" aria-hidden="true">

        <div class="modal-dialog" style="margin-left: 35%">
            <div class="modal-content" style="width:70%">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                    <h4 class="modal-title">Error</h4>
                </div>
                <div class="modal-body">
                     Please answer all the questions before submitting the exam.
                </div>

                <div class="modal-footer">
                    <button  type="button" class="btn btn-primary btn-sm" data-dismiss="modal"aria-hidden="true">CLOSE</button>
                </div> 

            </div>
        </div>
    </div>